//**********用户组可见/可管理范围模块***********/;
import request from '@/utils/request.js';

/**
 * 创建新的引用
 * @doc http://hanma-lesscode.hc-iiot.com/swagger-ui.html#!/
 * data 参数 
 *  componentIds:'', //可见范围模块id 	类型:array 非必填
 *  type:'', //1:可见范围 2：可管理范围 	类型:integer 非必填
 *  userGroupId:'', //用户组id 	类型:integer 非必填
 * @returns
 * ********
 */
export function postHmusergroupcomponent(data={}, config={}){
  return request({
    method: 'post',
    data,
    url: `/api/hmusergroupcomponent`,
    ...config,
  }) 
}

/**
 * 删除对应的组件
 * @doc http://hanma-lesscode.hc-iiot.com/swagger-ui.html#!/
 * params 参数 
 * id:'', //id 必填
 * @returns
 * ********
 */
export function deleteHmusergroupcomponent(params={}, config={}){
  return request({
    method: 'delete',
    params,
    url: `/api/hmusergroupcomponent`,
    ...config,
  }) 
}

/**
 * 获取所有已经选择的组件
 * @doc http://hanma-lesscode.hc-iiot.com/swagger-ui.html#!/
 * params 参数 
 * type:'', //type 必填
 * userGroupId:'', //userGroupId 必填
 * @returns
 * ********
 */
export function getHmusergroupcomponentList(params={}, config={}){
  return request({
    method: 'get',
    params,
    url: `/api/hmusergroupcomponent/list`,
    ...config,
  }) 
}

/**
 * 获取所有的的组件
 * @doc http://hanma-lesscode.hc-iiot.com/swagger-ui.html#!/
 * params 参数 
 * type:'', //type 必填
 * groupId:'', //groupId 必填
 * @returns
 * ********
 */
export function getHmusergroupcomponentSelectlist(params={}, config={}){
  return request({
    method: 'get',
    params,
    url: `/api/hmusergroupcomponent/select-list`,
    ...config,
  }) 
}